namespace SmartMathLibrary.Optimization
{
    /// <summary>
    /// Interface to implement a RealExtremum class.
    /// </summary>
    public interface IRealExtremum
    {
        /// <summary>
        /// Gets or sets the x value of the extremum.
        /// </summary>
        /// <value>The x value of the extremum.</value>
        double X { get; set; }

        /// <summary>
        /// Gets or sets the y value of the extremum.
        /// </summary>
        /// <value>The y value of the extremum.</value>
        double Y { get; set; }

        /// <summary>
        /// Gets or sets the type of the extremum.
        /// </summary>
        /// <value>The type of the extremum.</value>
        ExtremumType Type { get; set; }

        /// <summary>
        /// Compares the current instance to another one.
        /// </summary>
        /// <param name="compare">The instance compare.</param>
        /// <returns>True if the extremum values are even otherwise, false.</returns>
        bool CompareTo(RealExtremum compare);
    }
}